package com.mdd.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.mdd.common.R;
import com.mdd.dto.VoucherOrderDto;
import com.mdd.pojo.VoucherOrder;
import com.baomidou.mybatisplus.extension.service.IService;
import com.mdd.pojo.request.VoucherOrderAddRequest;
import com.mdd.pojo.request.VoucherOrderPageRequest;

/**
* @author 21958
* @description 针对表【voucher_order】的数据库操作Service
* @createDate 2023-04-04 23:01:24
*/
public interface VoucherOrderService extends IService<VoucherOrder> {

    /**
     * 生成普通优惠券订单
     * @param voucherOrderAddRequest
     * @return
     */
    R<Long> createVoucherOrder(VoucherOrderAddRequest voucherOrderAddRequest);

    /**
     * 生成秒杀订单
     * @param voucherOrderAddRequest
     * @return
     */
    R<Long> createSeckillOrder(VoucherOrderAddRequest voucherOrderAddRequest);

    /**
     * 优惠券订单分页
     * @param voucherOrderPageRequest
     * @return
     */
    R<Page<VoucherOrderDto>> voucherOrderPage(VoucherOrderPageRequest voucherOrderPageRequest);
}
